package com.ruoyi.common.core.domain.model;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.ruoyi.common.core.annotation.Excel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;

/**
 * 资产所有方资产信息对象 ams_own_asset
 * 
 * @author yfkj
 * @date 2021-10-15
 */
@Data
@AllArgsConstructor
@NoArgsConstructor
public class AmsOwnAsset extends com.ruoyi.common.core.web.domain.BaseEntity
{
    private static final long serialVersionUID = 1L;
    /** 资产所有方资产信息主键 */
    @TableField(exist = true)
    @ApiModelProperty(value =  "${comment}")
    @TableId(type= IdType.AUTO)
    private Long ownAssetId;
    /** 资产所属组织部门 */
    @Excel(name = "资产所属组织部门")
    @TableField(exist = true)
    @ApiModelProperty(value =  "资产所属组织部门")
    private Long ownDeptId;
    /** 资产使用组织部门 */
    @Excel(name = "资产使用组织部门")
    @TableField(exist = true)
    @ApiModelProperty(value =  "资产使用组织部门")
    private Long useDeptId;
    /** 资产 */
    @Excel(name = "资产")
    @TableField(exist = true)
    @ApiModelProperty(value =  "资产")
    private Long assetId;
    /** 资产位置 */
    @Excel(name = "资产位置")
    @TableField(exist = true)
    @ApiModelProperty(value =  "资产位置")
    private Long addressId;
    /** 资产标签 */
    @Excel(name = "资产标签")
    @TableField(exist = true)
    @ApiModelProperty(value =  "资产标签")
    private Long tagId;
    /** 资产实际使用人 */
    @Excel(name = "资产实际使用人")
    @TableField(exist = true)
    @ApiModelProperty(value =  "资产实际使用人")
    private Long userId;
    /** 是否删除(0删除，1正常) */
    @Excel(name = "是否删除(0删除，1正常)")
    @TableField(exist = true)
    @ApiModelProperty(value =  "是否删除(0删除，1正常)")
    private Integer isDelete;
    /** 来源(1购入，2自建，3租赁，4捐赠、5内部购入、6盘盈、7其他) */
    @Excel(name = "来源(1购入，2自建，3租赁，4捐赠、5内部购入、6盘盈、7其他)")
    @TableField(exist = true)
    @ApiModelProperty(value =  "来源(1购入，2自建，3租赁，4捐赠、5内部购入、6盘盈、7其他)")
    private String assetSource;
    /** 资产状态(1在用，2闲置，3借用，4报废，5调拨中，6维修中) */
    @Excel(name = "资产状态(1在用，2闲置，3借用，4报废，5调拨中，6维修中)")
    @TableField(exist = true)
    @ApiModelProperty(value =  "资产状态(1在用，2闲置，3借用，4报废，5调拨中，6维修中)")
    private String assetStatus;
    /** 开始使用时间 */
    @Excel(name = "开始使用时间")
    @TableField(exist = true)
    @ApiModelProperty(value =  "开始使用时间")
    private Long startUseTime;
    /** 截止使用时间 */
    @Excel(name = "截止使用时间")
    @TableField(exist = true)
    @ApiModelProperty(value =  "截止使用时间")
    private Long endUseTime;
    /** 可能的附件信息 */
    @Excel(name = "可能的附件信息")
    @TableField(exist = true)
    @ApiModelProperty(value =  "可能的附件信息")
    private String attachments;

    @TableField(exist = true)
    @ApiModelProperty(value =  "拥有方的组织部门祖级列表")
    private String ownDeptAncestors;
    public static final String OWN_ASSET_ID="own_asset_id";
    public static final String OWN_DEPT_ID="own_dept_id";
    public static final String USE_DEPT_ID="use_dept_id";
    public static final String ASSET_ID="asset_id";
    public static final String ADDRESS_ID="address_id";
    public static final String TAG_ID="tag_id";
    public static final String USER_ID="user_id";
    public static final String IS_DELETE="is_delete";
    public static final String ASSET_SOURCE="asset_source";
    public static final String ASSET_STATUS="asset_status";
    public static final String START_USE_TIME="start_use_time";
    public static final String END_USE_TIME="end_use_time";
    public static final String ATTACHMENTS="attachments";
    public static final String CREATE_BY="create_by";
    public static final String CREATE_TIME="create_time";
    public static final String UPDATE_BY="update_by";
    public static final String UPDATE_TIME="update_time";
    public static final String REMARK="remark";
    public static final String OWN_DEPT_ANCESTORS="own_dept_ancestors";
    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("ownAssetId", getOwnAssetId())
            .append("ownDeptId", getOwnDeptId())
            .append("useDeptId", getUseDeptId())
            .append("assetId", getAssetId())
            .append("addressId", getAddressId())
            .append("tagId", getTagId())
            .append("userId", getUserId())
            .append("isDelete", getIsDelete())
            .append("assetSource", getAssetSource())
            .append("assetStatus", getAssetStatus())
            .append("startUseTime", getStartUseTime())
            .append("endUseTime", getEndUseTime())
            .append("attachments", getAttachments())
            .append("createBy", getCreateBy())
            .append("createTime", getCreateTime())
            .append("updateBy", getUpdateBy())
            .append("updateTime", getUpdateTime())
            .append("remark", getRemark())
            .toString();
    }
}
